package site.addzero.cli.autoinit.common

import org.koin.core.annotation.Single
import site.addzero.cli.packagemanager.PackageManagerStrategty
import site.addzero.task.InitTask

@Single
class AutoInitPkg : InitTask {
    override val support: Boolean = true

    /**
     * 执行包管理器初始化任务
     */
    override suspend fun asynctask(): Boolean {
        val packageManagerStrategty = PackageManagerStrategty.Companion.getSupportPackageManager()
        return packageManagerStrategty.installSelf()
    }
}
